package com.mengwen.backstage.service.impl;


import com.mengwen.backstage.mapper.AdminMapper;
import com.mengwen.backstage.pojo.Admin;
import com.mengwen.backstage.service.AdminService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Transactional
@Service
public class AdminServiceImpl implements AdminService {

    @Autowired
    AdminMapper adminMapper;

    public Admin findByOpenid(String openid){
        return adminMapper.findByOpenid(openid);
    }

    @Override
    public Admin login(String accountNumber, String md5Password) {
        return adminMapper.login(accountNumber, md5Password);
    }
}
